import App from './App'
import {createRoot} from 'react-dom/client'
import store from "@/store/index";
import {Provider} from "react-redux";
import {BrowserRouter as Router} from 'react-router-dom';
import "@/css/reset.less"
import "@/css/global.less"
import React, {Suspense} from "react";

const container = document.getElementById('root') as Element
const root = createRoot(container)

root.render(
    <Provider store={store}>
        {/*注入全局store*/}
        <Suspense fallback={<h2>Loading..</h2>}>
            <Router>
                <App/>
            </Router>
        </Suspense>
    </Provider>
)
